//
//  ZFDownloadedCell.m
//  滴滴快拍
//
//  Created by dllo on 16/6/1.
//  Copyright © 2016年 dllo. All rights reserved.
//

#import "ZFDownloadedCell.h"

@implementation ZFDownloadedCell

/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
}
*/
- (instancetype) initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        [self createView];
    }
    return self;
    
}


- (void)createView {
    
    self.fileNameLabel = [[BaseLabel alloc] init];
    [self.contentView addSubview:self.fileNameLabel];
    
    self.sizeLabel = [[BaseLabel alloc] init];
    [self.contentView addSubview:self.sizeLabel];
    
    
    
}


- (void)layoutSubviews {
    [super layoutSubviews];
    self.fileNameLabel.frame = CGRectMake(15, 0, 200,30);
    self.sizeLabel.frame = CGRectMake(SCREEN_WIDTH - 100, 0, 100, 30);
    
}



- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];
    
    // Configure the view for the selected state
}

-(void)setSessionModel:(ZFSessionModel *)sessionModel
{
    _sessionModel = sessionModel;
    self.fileNameLabel.text = sessionModel.fileName;
    self.sizeLabel.text = sessionModel.totalSize;
    
}

@end
